<html><head><link href="loginmodule.css" rel="stylesheet" type="text/css" />

</head>
<body>

<?php
require_once ('config.php');
include_once ("common.php");
printAdminHeader();

$con = mysql_connect(DB_HOST, DB_USER, DB_PASSWORD);
if (!$con) {
	die('Could not connect: ' . mysql_error());
}

mysql_select_db(DB_DATABASE, $con);
$sql = "DELETE FROM movielist WHERE ID='$_POST[movieID]'";

if (!mysql_query($sql, $con)) {
	die('Error: ' . mysql_error());
}

mysql_close($con);
//echo "value is".$_POST['moviename'].$_POST['Mrating'];

echo "Movie deleted";
?>

</body>
</html>
